package com.design.mode.factory;

import java.util.Optional;

/**
 * @Date 2023/3/29 11:43:10
 * @Author luopeng
 */
public class ShapeFactoryDemo {
    public static void main(String[] args) {
        ShapeFactory.getShape("Circle").draw();
        ShapeFactory.getShape("Rectangle").draw();
        ShapeFactory.getShape("Square").draw();
//        ShapeFactory.getShape(null).draw();
//        ShapeFactory.getShape("xx").draw();
    }
}
